﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Microsoft.Xna.Framework.Content;
using Module_Basic_Entities;

namespace Module_Persistence
{
    internal class BLKSTRCustomContentTypeReader : ContentTypeReader
    {
        public BLKSTRCustomContentTypeReader(Type targetType)
            : base(targetType)
        {

        }

        protected override object Read(ContentReader input, object existingInstance)
        {

            BLKSTR block = new BLKSTR();

            block.User1 = input.ReadUInt32();

            block.User2 = input.ReadUInt32();

            block.User3 = input.ReadUInt16();

            block.User4 = input.ReadUInt16();

            block.User5 = input.ReadByte();

            block.User6 = input.ReadByte();

            block.User7 = input.ReadByte();

            return block as object;
        }
    }
}
